package com.ruibang.glass.quality.domain.req;

import com.alibaba.fastjson.annotation.JSONField;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.ruibang.glass.common.utils.validateannotation.NotBlank;
import com.teaming.cloud.framework2.common.pojo.PageRequest;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import org.springframework.format.annotation.DateTimeFormat;

import javax.validation.constraints.NotNull;
import java.time.LocalDate;

/**
 * @Author: songJinKang
 * @CreateTime: 2023-08-30  11:04
 * @Description: TODO
 * @Version: 1.0
 */
@Data
public class EverydayDiscardDefectReq extends PageRequest {

    @NotNull(message = "开始时间不可为空")
    @JsonFormat(pattern = "yyyy-MM-dd")
    @DateTimeFormat(pattern = "yyyy-MM-dd")
    @JSONField(format = "yyyy-MM-dd")
    private LocalDate startTime;

    @NotNull(message = "结束时间不可为空")
    @JsonFormat(pattern = "yyyy-MM-dd")
    @DateTimeFormat(pattern = "yyyy-MM-dd")
    @JSONField(format = "yyyy-MM-dd")
    private LocalDate endTime;

    @ApiModelProperty("检查机code")
    @NotBlank(message = "检查机不可为空")
    private String checkMachineCode;
}
